//
//  PageControlVC.m
//  CCPageControl
//
//  Created by Bager on 2017/10/11.
//  Copyright © 2017年 cccc. All rights reserved.
//

#import "PageControlVC.h"

#import "PageControlView.h"

@interface PageControlVC ()

@property(strong , nonatomic) PageControlView *pageControlV;
@property(strong , nonatomic) NSArray *imageArr;

@end

@implementation PageControlVC

- (void)viewDidLoad
{
    [super viewDidLoad];
    
    [self.view addSubview:self.pageControlV];
}

- (NSArray *)imageArr
{
    if (!_imageArr)
    {
        _imageArr = [NSArray arrayWithObjects:@"loading1",@"loading2",@"loading3", nil];
    }
    return _imageArr;
}

- (PageControlView *)pageControlV
{
    if (!_pageControlV)
    {
        _pageControlV = [[PageControlView alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height) andImageList:self.imageArr];
        DefineWeakSelf;
        _pageControlV.callBack = ^{
            weakSelf.callBack();
        };
    }
    return _pageControlV;
}

@end
